package com.poulpicious.ethanj.game;

import java.io.File;

import org.lwjgl.LWJGLUtil;
import org.newdawn.slick.AppGameContainer;
import org.newdawn.slick.GameContainer;
import org.newdawn.slick.SlickException;
import org.newdawn.slick.state.StateBasedGame;

import com.poulpicious.ethanj.states.SplashScreenState;
import com.poulpicious.ethanj.util.GameData;

public class EthanJackson extends StateBasedGame{

	public EthanJackson() {
		super(GameData.NAME);
	}

	@Override
	public void initStatesList(GameContainer gc) throws SlickException {
		addState(new SplashScreenState());
		enterState(GameData.SPLASH_SCREEN);
		
	}
	
	public static void main(String[] args) throws SlickException {
		System.setProperty("org.lwjgl.librarypath", new File(new File("lib/natives"), LWJGLUtil.getPlatformName()).getAbsolutePath());
		System.setProperty("net.java.games.input.librarypath", System.getProperty("org.lwjgl.librarypath"));
		AppGameContainer app = new AppGameContainer(new EthanJackson());
		app.setDisplayMode(GameData.WIDTH, GameData.HEIGHT, false);
		app.setVSync(true);
		app.start();
	}

}
